package com.lg.startertemplate.feign;



import org.apache.catalina.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;

/**
 *
 * 配置在dm里面有
 * 在研究这块的时候
 * 完成类似下面的接口 的传参 和调用  todo
 */
@FeignClient(value="${feign.gspId}",url="${feign.gspurl}")
public interface GeoserverFeign {

    @PostMapping("/rest/layergg/image1")
    public String publishLayer1();

    @PostMapping("/rest/layergg/image2/{workspacename}")
    public String publishLayer2(@PathVariable(value="workspacename") String workspacename,
                               @RequestHeader(name = "Authorization") String authorization);

    @PostMapping("/rest/layergg/image3/{workspacename}")
    public User publishLayer3(@PathVariable(value="workspacename") String workspacename,@RequestBody User car,
                               @RequestHeader(name = "Authorization") String authorization);

}
